using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._UtilityNetworkTools
{
    /// <summary>
    /// <para>Update Diagram</para>
    /// <para>Update Network Diagram</para>
    /// <para>更新网络图</para>
    /// </summary>    
    [DisplayName("Update Diagram")]
    public class UpdateDiagram : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public UpdateDiagram()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_diagrams">
        /// <para>Input Network or Network Diagram Layer</para>
        /// <para></para>
        /// <para></para>
        /// </param>
        public UpdateDiagram(object _in_diagrams)
        {
            this._in_diagrams = _in_diagrams;
        }
        public override string ToolboxName => "Utility Network Tools";

        public override string ToolName => "Update Diagram";

        public override string CallName => "un.UpdateDiagram";

        public override List<string> AcceptEnvironments => [];

        public override object[] ParameterInfo => [_in_diagrams, _template_names, _diagram_names, _update_option.GetGPValue(), _autolayout_option.GetGPValue(), _out_diagrams];

        /// <summary>
        /// <para>Input Network or Network Diagram Layer</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Network or Network Diagram Layer")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_diagrams { get; set; }


        /// <summary>
        /// <para>Template Names</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Template Names")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _template_names { get; set; } = null;


        /// <summary>
        /// <para>Diagram Names</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Diagram Names")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _diagram_names { get; set; } = null;


        /// <summary>
        /// <para>Update inconsistent diagrams only</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Update inconsistent diagrams only")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _update_option_value _update_option { get; set; } = _update_option_value._true;

        public enum _update_option_value
        {
            /// <summary>
            /// <para>INCONSISTENT_DIAGRAMS_ONLY</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("INCONSISTENT_DIAGRAMS_ONLY")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>ALL_SELECTED_DIAGRAMS</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("ALL_SELECTED_DIAGRAMS")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Re-apply automatic layouts on the updated diagrams</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Re-apply automatic layouts on the updated diagrams")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _autolayout_option_value _autolayout_option { get; set; } = _autolayout_option_value._false;

        public enum _autolayout_option_value
        {
            /// <summary>
            /// <para>REAPPLY_AUTOLAYOUT</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("REAPPLY_AUTOLAYOUT")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>DO_NOT_REAPPLY_AUTOLAYOUT</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("DO_NOT_REAPPLY_AUTOLAYOUT")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Output Network or Network Diagram Layer</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Network or Network Diagram Layer")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_diagrams { get; set; }


        public UpdateDiagram SetEnv()
        {
            base.SetEnv();
            return this;
        }

    }

}